#include("/include/pageForm.html",action="admin/clearing/collect/searchCollect")

<div class="pageHeader">
	<form rel="pagerForm" onsubmit="return navTabSearch(this);" action="admin/clearing/collect/searchCollect" method="post">
	<div class="searchBar">
		<ul class="searchContent">
			<li>
				<label>商户编号：</label>
				<input type="text" name="merchCode" value="#(merchCode)"/>
			</li>
			<li>
				<label>开始冻结日期：</label>
				<input type="text" name="payDateStart" value="#(payDateStart)" class="date textInput readonly valid" datefmt="yyyy-MM-dd"/> 
			</li>
			<li>
				<label>结束冻结日期：</label>
				<input type="text" name="payDateEnd" value="#(payDateEnd)" class="date textInput readonly valid" datefmt="yyyy-MM-dd"/> 
			</li>
			
		</ul>
		<ul class="searchContent">
			<li>
				<label>出账状态：</label>
				<select class="combox" name="compareStatus">
					<option value="">--全部--</option>
					<option value="1" #(paymentStatus == '1' ? 'selected' : '' )>冻结</option>
					<option value="2" #(paymentStatus == '2' ? 'selected' : '' )>解冻</option>
					<option value="3" #(paymentStatus == '3' ? 'selected' : '' )>未知</option>
					<option value="4" #(paymentStatus == '4' ? 'selected' : '' )>失败</option>
					<option value="5" #(paymentStatus == '5' ? 'selected' : '' )>成功</option>
				</select>
			</li>
			<li>
				<label>开始解冻日期：</label>
				<input type="text" name="payDateStart" value="#(payDateStart)" class="date textInput readonly valid" datefmt="yyyy-MM-dd"/> 
			</li>
			<li>
				<label>结束解冻日期：</label>
				<input type="text" name="payDateEnd" value="#(payDateEnd)" class="date textInput readonly valid" datefmt="yyyy-MM-dd"/> 
			</li>
		</ul>
		<div class="subBar">
			<ul>
				<li><div class="buttonActive"><div class="buttonContent"><button type="submit">检索</button></div></div></li>
				<li><div class="button"><div class="buttonContent"><button type="reset">重置</button></div></div></li>
			</ul>
		</div>
	</div>
	</form>
</div>

<div class="pageContent">
	<div class="panelBar">
		<ul class="toolBar">
			#auth()
				<li><a class="icon" href="admin/clearing/collect/viewCollect?id={id}" target="navTab"><span>明细</span></a></li>
			#end
			#auth()
				<li><a class="icon" href="admin/clearing/collect/payment" target="navTab"><span>出账</span></a></li>
			#end
		</ul>
	</div>

	<div id="w_list_print">
	<table class="list" style="width: 100%" targetType="navTab" asc="asc" desc="desc" layoutH="140">
		<thead>
			<tr>
				<th width="100">请求单号</th>
				<th width="60">渠道号</th>
				<th width="60">机构号</th>
				<th width="80">商户号</th>
				<th width="80">总数量</th>
				<th width="80">总金额</th>
				<th width="80">总手续费</th>
				<th width="80">出账金额</th>
				<th width="80">记账日期</th>
				<th width="60">付款状态</th>
				<th width="80">收款账号</th>
			</tr>
		</thead>
		<tbody>
			#for(item : items)
				<tr target="id" rel="#(item.id)">
					<td>#(item.orderNo )</td>
					<td>#(item.channelCode )</td>
					<td>#(item.orgCode )</td>
					<td>#(item.merchCode )</td>
					<td>#(item.sumCount )</td>
					<td>#number(item.amount.toDouble()/100, "##,###,##0.00")</td>
					<td>#number(item.fee.toDouble()/100, "##,###,##0.00")</td>
					<td>#number(item.paymentAmount.toDouble()/100, "##,###,##0.00")</td>
					<td>#(item.createDate )</td>
					<td>
						#if(item.paymentStatus == '0')
							初始
						#end
						#if(item.paymentStatus == '1')
							冻结
						#end
						#if(item.paymentStatus == '2')
							解冻
						#end
						#if(item.paymentStatus == '3')
							未知
						#end
						#if(item.paymentStatus == '4')
							失败
						#end
						#if(item.paymentStatus == '5')
							成功
						#end
					</td>
					<td>#(item.account )</td>
				</tr>
			#end
		</tbody>
	</table>
	</div>
	
	#include("/include/page.html")

</div>
